﻿using UnityEngine;
using UnityEditor;

namespace BToolkit
{
    public class ImportSetting : AssetPostprocessor
    {

        void OnPreprocessModel()
        {
            //ModelImporter importer = (ModelImporter)assetImporter;
            //importer.animationType = ModelImporterAnimationType.Legacy;
        }

        void OnPreprocessTexture()
        {
            //TextureImporter importer = (TextureImporter)assetImporter;
            //importer.textureType = TextureImporterType.Default;
            //importer.alphaIsTransparency = true;
            //importer.npotScale = TextureImporterNPOTScale.None;
            //importer.mipmapEnabled = false;
            //importer.textureCompression = TextureImporterCompression.Uncompressed;

            //var androidSettings = importer.GetPlatformTextureSettings("Android");
            //androidSettings.format = TextureImporterFormat.ETC2_RGBA8;
            //androidSettings.compressionQuality = 80;
            //androidSettings.overridden = true;
            //importer.SetPlatformTextureSettings(androidSettings);
        }

        void OnPreprocessAudio()
        {
            //AudioImporter importer = (AudioImporter)assetImporter;
            //importer.threeD = false;
        }
    }
}